package com.meida.module.bus.provider.controller;

import com.meida.common.mybatis.model.ResultBody;
import com.meida.common.springmvc.base.BaseController;
import com.meida.module.bus.client.entity.VipUser;
import com.meida.module.bus.provider.service.VipUserService;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.*;

import java.util.Map;


/**
 * vip用户表控制器
 *
 * @author flyme
 * @date 2022-06-30
 */
@RestController
@RequestMapping("/bus/vip/user/")
public class VipUserController extends BaseController<VipUserService, VipUser>  {

    @ApiOperation(value = "vip用户表-分页列表", notes = "vip用户表分页列表")
    @GetMapping(value = "page")
    public ResultBody pageList(@RequestParam(required = false) Map params) {
        return bizService.pageList(params);
    }

    @ApiOperation(value = "vip用户表-列表", notes = "vip用户表列表")
    @GetMapping(value = "list")
    public ResultBody list(@RequestParam(required = false) Map params) {
        return bizService.listEntityMap(params);
    }

    @ApiOperation(value = "vip用户表-添加", notes = "添加vip用户表")
    @PostMapping(value = "save")
    public ResultBody save(@RequestParam(required = false) Map params) {
        return bizService.add(params);
    }

    @ApiOperation(value = "vip用户表-更新", notes = "更新vip用户表")
    @PostMapping(value = "update")
    public ResultBody update(@RequestParam(required = false) Map params) {
        return bizService.edit(params);
    }

    @ApiOperation(value = "vip用户表-删除", notes = "删除vip用户表")
    @PostMapping(value = "remove")
    public ResultBody remove(@RequestParam(required = false) Map params) {
        return bizService.delete(params);
    }


    @ApiOperation(value = "vip用户表-详情", notes = "vip用户表详情")
    @GetMapping(value = "get")
    public ResultBody get(@RequestParam(required = false) Map params) {
        return bizService.get(params);
    }

}
